package cn.wolfcode.crm.domain;

import com.alibaba.fastjson.JSON;
import lombok.Getter;
import lombok.Setter;

import java.util.HashMap;
import java.util.Map;

@Getter
@Setter
public class SystemDictionaryItem {
    private Long id;

    private SystemDictionary systemDictionary;

    private String title;

    private Integer sequence;

    public String getJsonData() {
        Map<String, Object> map = new HashMap();
        map.put("id", this.id);
        map.put("systemDictionaryId", this.systemDictionary.getId());
        map.put("systemDictionaryTitle", this.systemDictionary.getTitle());
        map.put("title", this.title);
        map.put("sequence", this.sequence);
        return JSON.toJSON(map).toString();
    }
}